const mongoose = require("mongoose");

const db = require("./../mongodb/index");

const UserSchema = new db.Schema({
  name: String,
  id: Number,
  create_time: { type: Date, default: Date.now },
  update_time: { type: Date, default: Date.now },
});

UserSchema.index({ id: 1 });

const UserModel = mongoose.model("User", UserSchema);

module.exports = UserModel;
